<?php
/**
* 验证码 2013-4-26 by sutroon
* 例如：<div class="captcha"><div style="float:left; margin-top:10px;">请选<span>-</span>方块</div><div class="captcha-colors" style="float:left;">&nbsp;</div><div style="float:left; margin-top:10px;"><a href="###">[换一组]</a><input type="hidden" name="captcha" /></div><div style="clear:both;"></div></div>
*/
include_once('../Lib/CE/config.php');
if($wu->request_string('q')=='refresh'){
	$vars=array('lvse'=>'绿色','juse'=>'橘色','zise'=>'紫色','lanse'=>'蓝色','hongse'=>'红色');
	$colors=array_rand($vars,3);
	$colors=array_unique($colors);
	shuffle($colors);
	$id=$colors[array_rand($colors)];
	$_SESSION['captcha']=$id;
	$return=$vars[$id];
	foreach($colors as $c){
			$return.='<span class="yzm '.$c.'"></span>';
	}
	echo $return;
}
?>